<script>
function getT(id){ 
var e=document.getElementById(id);
var t=e.offsetTop; 
while(e=e.offsetParent){ 
t+=e.offsetTop; 
} 
return t 
}
</script>
